<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title></title>
</head>
<body>
    <div id="app">
        <!--<button v-on:click="test()"></button>-->
        <button @click="test(1)"></button>
        <!--<img v-bind:src="ddd">-->
        <img :src="img" >
        <span v-text="msg"></span>
        <input type="text" v-model="name" value="">
        <span>{{name}}</span>
    </div>
</body>
<script src="./js/vue.js" type="text/javascript"></script>
<script>
    var vm= new Vue({
        el:"#app",
        data:{  //管理状态数据
            img:"../../img/4.jpg_.webp",
            name:"LISI"
        },
        methods:{
            test(num) {
                console.log(this.name)
                alert(num)
            }
        }

    })
</script>
</html>